<!DOCTYPE html>
<html>
  <head>
    <base href="/">
    <meta charset="utf-8">
    <meta http-equiv="x-ua-compatible" content="ie=edge">
    <meta name="renderer" content="webkit">
    <title>{wc:$webname}</title>
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
<link href="{G_TEMPLATES_CSS}/mobile/comm.css" rel="stylesheet" type="text/css" />
<link href="{G_TEMPLATES_CSS}/mobile/index.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" href="{G_TEMPLATES_CSS}/mobile/reset.css">
<link rel="stylesheet" href="{G_TEMPLATES_CSS}/mobile/animate.css">
<link rel="stylesheet" href="{G_TEMPLATES_CSS}/mobile/style.css">
<link href="{G_TEMPLATES_CSS}/mobile/main.css" rel="stylesheet" type="text/css">

<link href="{G_TEMPLATES_IMAGE}/mobile/touch-icon.png" rel="apple-touch-icon-precomposed" />
<link href="favicon.ico" rel="shortcut icon" />
<link href="{G_TEMPLATES_CSS}/mobile/comm.css" rel="stylesheet" type="text/css" />
<link href="{G_TEMPLATES_CSS}/mobile/index.css" rel="stylesheet" type="text/css" />
<link href="{G_TEMPLATES_CSS}/mobile/goods.css" rel="stylesheet" type="text/css" />




<script src="{G_TEMPLATES_JS}/mobile/jquery.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/js.cookie.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/lodash.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/response.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/swiper.min.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/countdown.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/simpop.min.js"></script>
<script src="{G_TEMPLATES_JS}/mobile/jquery.lazyload.min.js"></script>
<script>
var DuoBao = {};
var __data__ = (function(){
  return JSON.parse('{}');
})();
var __user__ = (function(){
  return JSON.parse('{}');

})();
var __touchorclick__ = (function(){
  if ('ontouchend' in document)
    return 'touchend';
  else
    return 'click';
})();
</script>
<!--下载提示 -->
<div class="m-qzbdkhd">
<span class="close" onClick="this.parentNode.style.display='none'"></span>
<a href="http://www.appbsl.com/index.php?ctl=app_download&id=10166" rel=" nofollow">
<i class=""><img src="http://www.teyunbao.cn/ys/appxz.png" width="00" height="00"/></i>
一<s></s>元<s></s>云<s></s>购<s></s>夺<s></s>宝<s></s> 惊<s></s>喜<s></s>无<s></s>限
<i class="u-dlRnow">APP<s></s><s></s>下<s></s>载</i>
</a>
</div>
<style>
.m-qzbdkhd{height:40px;background:#ffffff; line-height: 40px; position:relative;border-bottom:1px solid #eecdcd; padding-left: 50px; font-size: 15px; color: #6f6f6f;}
.u-khdLogo{ width: 28px; display: inline-block; float: left; margin: 10px 10px 0px 0px; height: 34px; overflow: hidden;}
.u-khdLogo img{ width:100%;}
.m-qzbdkhd a{ color: #6f6f6f;-webkit-tap-highlight-color: rgba(255, 255, 255, 0); -webkit-user-select: none;
-moz-user-focus: none; -moz-user-select: none;}
.m-qzbdkhd s{display:none;}
.m-qzbdkhd .close{width:20px;height:20px;color:#FF0000;text-align:center;line-height:20px;font-size:20px;border-radius:10px;cursor:pointer;position:absolute;left:10px;top:11px;background:#FF0000 url() 4px 4px no-repeat; background-size: 12px;}
.m-qzbdkhd .u-dlRnow{ display: inline-block; float: right; font-size: 15px; color: #fff; height: 22px; padding: 0px 8px; background-color: #ff425e; border-radius: 4px; line-height: 22px; margin: 9px 10px 0px 0px;}
</style>

</head>
  <style>
    .img-topright {
      padding-right: 0.8rem;
      padding-top: 1rem;
      height: 3.5rem;
      width: auto;
      float: right;
    }
  </style>

  <body >
{wc:templates "mobile/index","header"}
    <div class="container">
<main class="db-main db-main-index">
<style type="text/css">
.zxjx>a:link, .zxjx>a:visited, .zxjx>a:hover, .zxjx>a:active,
.tabs>a:link, .tabs>a:visited, .tabs>a:hover, .tabs>a:active {
    color: #323232;
}
.tab_selected {
    color: #ff5151;
    border-bottom: 3px solid #ff5151;
}
.color_blue {
    color: #2a99e0;
}
.btn_buy {
    font-size: 1rem;
    border-radius: 0.3rem;
    border: 1px solid #ff5151;
    color: #ff5151;
    text-align: center;
    padding: 0.5rem 0.3rem;
}
.item_bottom_container {
   overflow: hidden;
   padding: 0 5%;
   margin-top: 0.8rem;
   font-size: 1rem;
}
.jdt_container {
    float: left;
    width: 60%;
}
.jdt_container div {
    color: #646464;
}
.buy_container {
    float: left;
    width: 40%;
    text-align: center;
}
.tab_load_more {
    text-align: center;
    color: #868686;
    font-size: 1.2rem;
    padding: 0.8rem 0rem 0rem;
}
</style>
    <!-- 焦点图1 -->
    <div class="swiper-container">
      <div class="swiper-wrapper">
       {wc:loop $shop_ad $ad}
        <div class="swiper-slide swiper-slide-active">
          <a href="{wc:$ad['link']}">
            <img alt="{wc:$ad['title']}" src="{G_UPLOAD_PATH}/{wc:$ad['img']}">
          </a>
        </div>
        {wc:loop:end}  
      </div>
      <div class="swiper-pagination swiper-pagination-clickable"><span class="swiper-pagination-bullet swiper-pagination-bullet-active"></span><span class="swiper-pagination-bullet"></span></div>
    </div>
    <script> 
    var mySwiper = new Swiper('.swiper-container', {
      autoplay: 5000,//可选选项，自动滑动
      pagination : '.swiper-pagination',
      paginationClickable :true,
    })
    </script>
  <div class="zxjx">
    <a href="{WEB_PATH}/mobile/mobile/lottery">最新揭晓<label style="position:absolute; right:1rem; cursor:pointer">显示全部&nbsp;></label></a>
    <ul class="ul ">
      <script>
        (function(){
          DuoBao.refresh_prize = function refresh_prize(){
            var $el = $($(this).data('dom_id'));
            $.get($el.attr('title'), {raw_only: 'true'}, function(data){
                $el.html(data);
            });
          };

        })();
      </script>
     {wc:loop $shopqishu $k $qishu}
      {wc:php:start}
                  $qishu['q_user'] = unserialize($qishu['q_user']);
      {wc:php:end}
      
      <li>
        <a href="{WEB_PATH}/mobile/mobile/item/{wc:$qishu['id']}" id="r{wc:$qishu['id']}" title="{WEB_PATH}/mobile/mobile/itemajax/{wc:$qishu['id']}">
          <div style="width:90%; margin-left:5%;">
            <img  style="width:90%; margin-left:5%;" src="{G_UPLOAD_PATH}/{wc:$qishu['thumb']}" height="108" width="208" class="lazy_loading_image">
          </div>
          <div class="txt" style="">
            <h6>{wc:fun:_strcut($qishu['title'],20)}</h6>
            {wc:if $qishu['q_showtime']=='N'}
            <div class="zj"><span>中奖</span><span style="color: #5bb6ea;">{wc:fun:get_user_name($qishu['q_uid'],'username')}</span></div>
            {wc:else}
            <div class="zj">
            <div style="text-align:center; padding: 0.2rem;white-space: nowrap; text-overflow: ellipsis; overflow: hidden; background-color:#ff5151; color:#fff; border-radius:1rem;">
              <time class="countdown"
                style="white-space: nowrap; text-overflow: ellipsis; overflow: hidden;"
                data-dom_id="#r{wc:$qishu['id']}"
                data-sec="{wc:fun:ceil($qishu['q_end_time']-time())}"
                data-text="正在揭晓..."
                data-delay="1000"
                data-callback="DuoBao.refresh_prize">开始倒计时</time>
            </div>
            </div>
            {wc:if:end}
          </div>
        </a>
      </li>
       {wc:loop:end}
    </ul>
  </div>
  
  


  <div class="tabs-wrap" style="min-height:1000px;">
    <div class="zxjx">
      <a href="{WEB_PATH}/mobile/mobile/glist" class="tab_selected" data-order_by='level'>热门推荐<label style="position:absolute; right:1rem; cursor:pointer">显示全部&nbsp;></label></a>
    </div>
    <div class="tabs-content">
      <ul class="ul">
      {wc:loop $shoplistrenqi $renqi}
           <li id="{wc:$renqi['id']}">
           <a id="prize_url" href="javascript:;" class="add1" codeid="{wc:$renqi['id']}" >
             <img style="display: block;" data-original="{G_UPLOAD_PATH}/{wc:$renqi['thumb']}" id="prize_image" src="{G_UPLOAD_PATH}/{wc:$renqi['thumb']}">
             <h6 id="prize_title">{wc:$renqi['title']}</h6>
             <div class="item_bottom_container">
               <div class="jdt_container">
                 <div>进度&nbsp;<label class="color_blue" id="jd">{wc:fun:percent($renqi['canyurenshu'],$renqi['zongrenshu'])}</label></div>
                 <span class="jdt" style="margin-left:0rem;"><span style="width:{wc:$renqi['canyurenshu']/$renqi['zongrenshu']*100}%;"></span></span>
               </div>
               <div class="buy_container">
                 <div class="btn_buy">立即夺宝</div>
               </div>
             </div>
           </a>
         </li>
          {wc:loop:end}
      </ul>
 <script type="text/javascript">
      //打开页面加载数据
      window.onload=function(){
      	//购物车数量
      	$.getJSON('{WEB_PATH}/mobile/ajax/cartnum',function(data){
      		if(data.num){
      			$("#btnCart").append('<em>'+data.num+'</em>');
      		}
      	});
      }
      	//添加到购物车
      	$(document).on("click",'.add1',function(){
      		var codeid=$(this).attr('codeid');
      		window.location.href="{WEB_PATH}/mobile/mobile/item/"+codeid;	
      	});
</script>
	  
 
 <div class="zxjx">
      <a href="{WEB_PATH}/mobile/mobile/glist" class="tab_selected" data-order_by='level'>即将揭晓<label style="position:absolute; right:1rem; cursor:pointer">显示全部&nbsp;></label></a>
    </div>
	    	
<!-- 栏目页面顶部 -->



<!-- 内页顶部 -->


	    <!-- 导航 -->

        <!-- 列表 -->
        <div class="goodsList">
            <div id="divGoodsLoading" class="loading" style="display:none;"><b></b>正在加载...</div>
            <a id="btnLoadMore" class="loading" href="javascript:;" style="display:none;">点击加载更多</a>
            <a id="btnLoadMore2" class="loading"  style="display:none;">没有数据</a>
            <a id="btnLoadMore3" class="loading"  style="display:none;">已经到底了</a>
        </div>	
    </section>
	
    <input id="urladdress" value="" type="hidden" />
    <input id="pagenum" value="" type="hidden" />
{wc:templates "mobile/index","footer"}
<script type="text/javascript">

//打开页面加载数据
window.onload=function(){
	glist_json("list/10");
	//购物车数量
	$.getJSON('{WEB_PATH}/mobile/ajax/cartnum',function(data){
		if(data.num){
			$("#btnCart").append('<em>'+data.num+'</em>');
		}
	});
	
}
//获取数据
function glist_json(parm){
	$("#urladdress").val('');
	$("#pagenum").val('');
	$.getJSON('{WEB_PATH}/mobile/mobile/glistajax/'+parm,function(data){
		$("#divGoodsLoading").css('display','none');		
		if(data[0].sum){
			var fg=parm.split("/");
			$("#urladdress").val(fg[0]+'/'+fg[1]);
			$("#pagenum").val(data[0].page);
			var ul='<ul>';			
			if($(".goodsList ul").find("li").length>0){ul='';}								
			for(var i=0;i<data.length;i++){			
			//var ul='<ul><li>';
				//ul+='<span id="'+data[i].id+'" class="z-Limg"><img src="{G_UPLOAD_PATH}/'+data[i].thumb+'"></span>';
				//ul+='<div class="goodsListR">';
				//ul+='<h2 id="'+data[i].id+'">'+data[i].title+'</h2>';
				//ul+='<div class="pRate">';
				//ul+='<div class="Progress-bar" id="'+data[i].id+'">';				
				//ul+='<p class="u-progress"><span class="pgbar" style="width:'+(data[i].canyurenshu / data[i].zongrenshu)*100+'%;"><span class="pging"></span></span></p>';
				//ul+='<ul class="Pro-bar-li">';
				//ul+='<li class="P-bar01"><em>'+data[i].canyurenshu+'</em>已参与</li>';
				//ul+='<li class="P-bar02"><em>'+data[i].zongrenshu+'</em>总需人次</li>';
				//ul+='<li class="P-bar03"><em>'+data[i].shenyurenshu+'</em>剩余</li>';
				//ul+='</ul></div>';
				//ul+='<a class="add " codeid="'+data[i].id+'" href="javascript:;"><s></s></a>';
				//ul+='</div></div></li></ul>';
		
				ul+='<li id="'+data[i].id+'" style="float: left;width: 50%;line-height: 0;    border-bottom: 1px solid #DCDCDC;">';
				    if(i%2==0){
						ul+='<a id="prize_url" href="javascript:;" class="add1" codeid="'+data[i].id+'" style=" display: inline-block;    line-height: 1.25em;    height: 100%;    width: 100%;border-right: 1px solid transparent;    padding-bottom: 1rem;border-right-color: #DCDCDC;">';
					}else{
						ul+='<a id="prize_url" href="javascript:;" class="add1" codeid="'+data[i].id+'" style=" display: inline-block;    line-height: 1.25em;    height: 100%;    width: 100%;border-right: 1px solid transparent;    padding-bottom: 1rem;">';
					}				   
					 ul+='<img style="    height: 9rem;    width: 9rem;margin: 1rem auto;display: block;" data-original="http://3m.zx58.cc/statics/uploads/shopimg/20160527/54835718320872.jpg" id="prize_image" src="{G_UPLOAD_PATH}/'+data[i].thumb+'">';
					 ul+='<h6 id="prize_title" style="padding: 0 5%;    font-size: 1.2rem;    white-space: nowrap;    text-overflow: ellipsis;    overflow: hidden;">'+data[i].title+'</h6>';
					 ul+='<div class="item_bottom_container" style="overflow: hidden;    padding: 0 5%;    margin-top: 0.8rem;font-size: 1rem;">';
					   ul+='<div class="jdt_container" style="    float: left;    width: 55%">';
						 ul+='<div>进度&nbsp;<label class="color_blue" id="jd">'+((data[i].canyurenshu / data[i].zongrenshu)*100).toFixed(2)+'%</label></div>';
						 ul+='<span class="jdt" style="margin-left:0rem;"><span style="width:'+(data[i].canyurenshu / data[i].zongrenshu)*100+'%;"></span></span>';
					   ul+='</div>';
					   ul+='<div class="buy_container" style="    float: left;width: 45%; text-align: center;">';
						 ul+='<div class="btn_buy">立即夺宝</div>';
					   ul+='</div>';
					 ul+='</div>';
				   ul+='</a>';
				 ul+='</li>	';							
				//$("#divGoodsLoading").before(ul);							
			}
			if($(".goodsList ul").find("li").length<1){ul+='</ul>	';}				
			$("#divGoodsLoading").before(ul);	
			if(data[0].page<=data[0].sum){
				$("#btnLoadMore").css('display','block');
				$("#btnLoadMore2").css('display','none');
				$("#btnLoadMore3").css('display','none');
			}else if(data[0].page>data[0].sum){
				$("#btnLoadMore").css('display','none');
				$("#btnLoadMore2").css('display','none');
				$("#btnLoadMore3").css('display','block');
			}
		}else{
			$("#btnLoadMore").css('display','none');
			$("#btnLoadMore2").css('display','block');	
			$("#btnLoadMore3").css('display','none');			
		}
	});
}
$(document).ready(function(){
	//即将揭晓,人气,最新,价格	
	$("#divGoodsNav li:not(:last)").click(function(){
		var l=$(this).index();
		$("#divGoodsNav li").removeClass().eq(l).addClass('current');
		var parm=$("#divGoodsNav li").eq(l).attr('order');
		$("#divGoodsLoading").css('display','block');
		$(".goodsList ul").remove();
		var glist=glist_json("list/"+parm);
	});
	
	//商品分类
	var dl=$("#divGoodsNav dl"),
		last=$("#divGoodsNav li:last"),
		first=$("#divGoodsNav dd:first");
	$("#divGoodsNav li:last a:first").click(function(){		
		if(dl.css("display")=='none'){
			dl.show();
			last.addClass("gSort");
			first.addClass("sOrange");			
		}else{
			dl.hide();
			last.removeClass("gSort");
			first.removeClass("sOrange");
		}
	});
	$("#divGoodsNav  dd").click(function(){
		var s=$(this).index();
		var t=$("#divGoodsNav .gSort dd a").eq(s).html();
		var id=$("#divGoodsNav .gSort dd a").eq(s).attr('id');
		$("#divGoodsNav .gSort a:first").html(t+'<s class="arrowUp"></s>');
		var l=$("#divGoodsNav .current").index(),
			parm=$("#divGoodsNav li").eq(l).attr('order');
		if(id){			
			$("#divGoodsLoading").css('display','block');
			$(".goodsList ul").remove();
			glist_json(id+'/'+parm);
		}else{
			glist_json("list/"+parm);
			$(".goodsList ul").remove();
		}	
		dl.hide();
		last.removeClass("gSort");
		first.removeClass("sOrange");
	});
	//加载更多
	$("#btnLoadMore").click(function(){		
		var url=$("#urladdress").val(),
			page=$("#pagenum").val();
		glist_json(url+'/'+page);
	});	
	//返回顶部
	$(window).scroll(function(){
		if($(window).scrollTop()>50){
			$("#btnTop").show();
		}else{
			$("#btnTop").hide();
		}
	});
	$("#btnTop").click(function(){
		$("body").animate({scrollTop:0},10);
	});
	//添加到购物车
	$(document).on("click",'.add',function(){
		var codeid=$(this).attr('codeid');
		$.getJSON('{WEB_PATH}/mobile/ajax/addShopCart/'+codeid+'/1',function(data){
			if(data.code==1){
				addsuccess('添加失败');
			}else if(data.code==0){
				addsuccess('添加成功');				
			}return false;
		});
	});
	function addsuccess(dat){
		$("#pageDialogBG .Prompt").text("");
		var w=($(window).width()-255)/2,
			h=($(window).height()-45)/2;
		$("#pageDialogBG").css({top:h,left:w,opacity:0.8});
		$("#pageDialogBG").stop().fadeIn(1000);
		$("#pageDialogBG .Prompt").append('<s></s>'+dat);
		$("#pageDialogBG").fadeOut(1000);
		//购物车数量
		$.getJSON('{WEB_PATH}/mobile/ajax/cartnum',function(data){
			$("#btnCart").append('<em>'+data.num+'</em>');
		});
	}
	//跳转页面
	var gt='.goodsList span,.goodsList h2,.goodsList .Progress-bar';
	$(document).on('click',gt,function(){
		var id=$(this).attr('id');
		if(id){
			window.location.href="{WEB_PATH}/mobile/mobile/item/"+id;
		}			
	});

});

</script>	  

<footer class="footer">
   <!-- <div class="u-ft-nav" id="fLoginInfo">
        <span><a href="{WEB_PATH}/mobile/mobile/">首页</a><b></b></span>
      <span><a href="{WEB_PATH}/mobile/mobile/about">新手指南</a><b></b></span>
      <span><a href="{WEB_PATH}/mobile/user/login">登录</a><b></b></span>
      <span><a href="{WEB_PATH}/mobile/user/register">注册</a></span>
    </div>
    <p class="m-ftA">
      <a href="{WEB_PATH}/mobile/mobile">触屏版</a>|<a href="{WEB_PATH}">电脑版</a> 
    </p>
    <p class="grayc">客服热线<span class="orange">{wc:fun:_cfg('cell')}</span></p>
    <p class="grayc">{wc:fun:_cfg('web_copyright')}</p>
    <a id="btnTop" href="javascript:;" class="z-top" style="display:none;"><b class="z-arrow"></b></a>
   </footer>-->
    </div>
  </div>
</main>
 <script src="{G_TEMPLATES_JS}/mobile/main.js"></script> 
</div>
   {wc:php:start}
    $f_home = '';
    $f_whole = '';
    $f_jiexiao = '';
    $f_car = '';
    $f_personal = '';

    if( ROUTE_C == 'home' || ROUTE_C == 'user' ){
      $f_personal = 'cur';
    }else if( ROUTE_C == 'mobile' && ROUTE_A == 'init'){
      $f_home = 'cur';
    }else if( ROUTE_C == 'mobile' && ROUTE_A == 'glist'){
      $f_whole = 'cur';
    }else if( ROUTE_C == 'mobile' && ROUTE_A == 'lottery'){
      $f_jiexiao = 'cur';
    }else if( ROUTE_C == 'shaidan'){
      $f_car = 'cur';
    }
   {wc:php:end}

   <style>
   .footerdi .f_home i.cur{
    background-position: 0 0 !important;
   }
   .footerdi .f_whole i.cur{
    background-position: 0 -52px !important;
   }
   .footerdi .f_jiexiao i.cur{
    background-position: 0 -222px !important;
   }
   .footerdi .f_car i.cur{
    background-position: 0 -105px !important;
   }
   .footerdi .f_personal i.cur{
    background-position: 0 -152px !important;
   }
   </style>   
   <div class="footerdi" style="bottom: 0px;">
    <ul>
      <li class="f_home">
        <a title="首页" href="{WEB_PATH}/mobile/mobile/"><i class="{wc:$f_home}">&nbsp;</i>首页</a>
      </li>
      <li class="f_whole">
        <a title="商品列表" href="{WEB_PATH}/mobile/mobile/glist"><i class="{wc:$f_whole}">&nbsp;</i>商品列表</a>
      </li>
      <li class="f_jiexiao">
        <a title="最新揭晓" href="{WEB_PATH}/mobile/mobile/lottery"><i class="{wc:$f_jiexiao}">&nbsp;</i>最新揭晓</a>
      </li>
      <li class="f_car">
      	<a title="购物车" href="{WEB_PATH}/mobile/cart/cartlist"><i class="{wc:$f_car}">&nbsp;</i>购物车</a>
      </li>
      <li class="f_personal">
        <a title="个人中心" href="{WEB_PATH}/mobile/user/login"><i class="{wc:$f_personal}">&nbsp;</i>个人中心</a>
      <li>
    </ul>
   </div>
  </body>
</html>
<style>
#pageDialogBG{-webkit-border-radius:5px; width:255px;height:45px;color:#fff;font-size:16px;text-align:center;line-height:45px;}
</style>
<div id="pageDialogBG" class="pageDialogBG">
<div class="Prompt"></div>
</div>


	  <style>
 .contact-public{
    position:fixed;
    right:0px;
    width:30px;
    padding:0;
    line-height:15px;
    border-radius:5px;
    background:rgba(255, 222, 173, 1);
    bottom:70px;
    text-align:center;
    color:#fff;
    z-index:2;
 }
.contact-public li{
   display:block;
   border-bottom:1px solid #7D7D7D;
   text-align:center;
               -webkit-box-sizing:border-box;
                  -moz-box-sizing:border-box;
                     -o-box-sizing:border-box;   
                        box-sizing:border-box;
}
.contact-public li:last-child{
   border-bottom:0;
   border-top:1px solid #242424;
}
.contact-public a{
   display:block;
   color:#FD94FC;
   font-size:16px;
   text-align:center;
   padding:6px;
}
.contact-public .icon-tel{
   display:block;
   margin:0px auto 0 auto;
   width:25px;
   height:20px;
   background:url("http://wfx.91dcw.com/weixin/images/distribution2.png") -200px -820px;
   background-size:300px 1000px;
}
</style>
<ul style="display: ;" class="contact-public">
                  <a target="_blank" href="http://wpa.qq.com/msgrd?v=3&uin={wc:fun:_cfg("qq")}&site=qq&menu=yes">联<br>系<br>客<br>服</a>          
 </ul>
 <script>
   wx.config({
     debug: false,
     appId: "{wc:php:start} echo $wechat['appid'];{wc:php:end}",
     timestamp: {wc:php:start} echo $signPackage["timestamp"];{wc:php:end},
     nonceStr: '{wc:php:start} echo $signPackage["nonceStr"];{wc:php:end}',
     signature: '{wc:php:start} echo $signPackage["signature"];{wc:php:end}',
   jsApiList: ["checkJsApi", "onMenuShareAppMessage", "onMenuShareTimeline", "onMenuShareWeibo", "onMenuShareQQ"]
   });
 wx.ready(function () {
 var n = $("#hidLineLink").val();
     wx.onMenuShareTimeline({
         title: "1元就能购买iphone6哦，快去看看吧！", // 分享标题
         link: n, // 分享链接
         imgUrl: "{G_TEMPLATES_STYLE}/images/mobile/iphone6.jpg", // 分享图标
         success: function () { 
            alert('已分享');
         },
         cancel: function () { 
             alert('已取消');
         }
     });
     wx.onMenuShareAppMessage({
         title: "1元就能购买iphone6哦，快去看看吧！", // 分享标题
         desc: "1元就能购买iphone6哦，快去看看吧！", // 分享描述
         link: n, // 分享链接
         imgUrl: "{G_TEMPLATES_STYLE}/images/mobile/iphone6.jpg", // 分享图标
         type: '', // 分享类型,music、video或link，不填默认为link
         dataUrl: '', // 如果type是music或video，则要提供数据链接，默认为空
          success: function () { 
            alert('已分享');
         },
         cancel: function () { 
             alert('已取消');
         }
     });
     wx.onMenuShareQQ({
         title: "1元就能购买iphone6哦，快去看看吧！", // 分享标题
         desc: "1元就能购买iphone6哦，快去看看吧！", // 分享描述
         link: n, // 分享链接
         imgUrl: "{G_TEMPLATES_STYLE}/images/mobile/iphone6.jpg", // 分享图标
         success: function () { 
            // 用户确认分享后执行的回调函数
         },
         cancel: function () { 
            // 用户取消分享后执行的回调函数
         }
     });
     wx.onMenuShareWeibo({
         title: "1元就能购买iphone6哦，快去看看吧！", // 分享标题
         desc: "1元就能购买iphone6哦，快去看看吧！", // 分享描述
         link: n, // 分享链接
         imgUrl: "{G_TEMPLATES_STYLE}/images/mobile/iphone6.jpg", // 分享图标
         success: function () { 
            alert('已分享');
         },
         cancel: function () { 
             alert('已取消');
         }
     });
 });
 </script>